<!-- 废页，内容按/pages/dispatch/shopDetails/shopDetails为准 -->
<template>
	<view>
		<view class="lunbo">
			<swiper :indicator-dots="yincang" class="swiper" circular indicator-dots indicator-color="#ffffff">
				<swiper-item v-for="(item, index) in lunbo" :key='index'>
					<image :src="item" mode="aspectFill" class="swiper-image" />
				</swiper-item>
			</swiper>
		</view>
		<view class="neirong">
			<image :src="'https://www.lichu2025.cn/'+con.avatar" class='touxiang' type='widthFix'></image>
			<text class="dianming">{{con.shopname}}</text>
			<text class="guanzhu">{{con.follow}}</text>
			<text class="renjun">{{con.per_capita}}</text>
			<text class="dizhi">{{con.dizhi}}</text>
			<text class="yuexiao">{{con.monthly_sales_order}}</text>
			<text class="junin">{{con.fromyou}}</text>
			<image src="/static/daohang.svg"/>
			<image class='daohang' src="/static/images/daohang.svg"></image>
			<image class='dianhua' src="/static/images/dianhua.svg"></image>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				lunbo: [],
				yincang: false,
				con: {
				  "id": 6,
				  "monthly_sales_order": 5,
				  "per_capita": "23.40",
				  "user_id": 18,
				  "shopname": "哈尔滨店铺",
				  "keywords": "超 ",
				  "description": "店铺的介绍啊",
				  "service_ids": [
				    {
				  	"id": 1,
				  	"name": "7天无理由退款",
				  	"description": "满足退款条件，用户可申请七天无理由退款"
				    },
				    {
				  	"id": 3,
				  	"name": "48小时内发货",
				  	"description": "商家保障，48小时内发出货品"
				    }
				  ],
				  "avatar": "/uploads/20250214/735692873e8b48efb920e6e97ed3162b.jpg",
				  "state": "1",
				  "level": 0,
				  "islive": 0,
				  "isself": 0,
				  "bio": null,
				  "city": "黑龙江省/哈尔滨市/松北区",
				  "return": "",
				  "like": 0,
				  "score_describe": 5,
				  "score_service": 5,
				  "score_deliver": 5,
				  "score_logistics": 5,
				  "weigh": 6,
				  "verify": "3",
				  "createtime": 1739517014,
				  "updatetime": 1740128264,
				  "deletetime": null,
				  "status": "normal",
				  "qrcode": null,
				  "longitude": "126.495384",
				  "latitude": "45.789246",
				  "district": null,
				  "province": null,
				  "address": "黑龙江省哈尔滨市平房区渤海路副6号(动漫基地F座)2单元502室(集群注册)",
				  "lat": "45.789246",
				  "lng": "126.495384",
				  "qualification_image": "/uploads/20250214/3b165db7a6a8b6714a0fb807384867c1.jpg",
				  "shop_image": "/uploads/20250214/1216ca08ba4beda2826880a8c4ddaa31.jpg,/uploads/20250214/1216ca08ba4beda2826880a8c4ddaa31.jpg",
				  "scope_business": "一般项目:计算机软硬件的技术开发、技术咨询、技术服务、技术转让;网页设计;企业营销策划;设计、制作、代理、发布国内广告业务;成年人专业技术和业务知识培训(不含学历教育,不含需取得许可审批方可经营的职业技能或者职业资格培训项目)。(依法须经批准的项目,经相关部门批准后方可开展经营活动,具体经营项目以相关部门批准文件或许可证件为准)",
				  "start_time": "03:00",
				  "end_time": "23:09",
				  "id_card_frontage": "/uploads/20250214/c7396b4d4b8a73b393a2cc047b872afd.jpg",
				  "id_card_opposite": null,
				  "shop_code": "258769130",
				  "shop_code_image": "/uploads/qrcode/9f091753c68df49f7b0bbb5596ed59c5.png",
				  "mobile": null,
				  "commission_ratio": "10.00",
				  "is_tui": 0,
				  "score": 5,
				  "self_recive": 0,
				  "fromyou": 8133.662644588083,
				  "find_user": {
				    "user_no": "158369724",
				    "fans": 1
				  }
				}
			};
		},
		mounted() {
			this.chushihua()
			// this.huoqujingweidu()
			// this.huoquxiangqing()
			this.loadData()
		},
		methods:{
			chushihua(){
				this.lunbo = ['https://www.lichu2025.cn/uploads/20250318/f7c672530bcec38aed0a462489dfd1e5.png?x-oss-process=image/auto-orient,1/interlace,1/format,jpg/quality,q_90/sharpen,50/resize,m_fill,w_360,h_360', 'https://www.lichu2025.cn/uploads/20250318/f7c672530bcec38aed0a462489dfd1e5.png?x-oss-process=image/auto-orient,1/interlace,1/format,jpg/quality,q_90/sharpen,50/resize,m_fill,w_360,h_360', 'https://www.lichu2025.cn/uploads/20250318/f7c672530bcec38aed0a462489dfd1e5.png?x-oss-process=image/auto-orient,1/interlace,1/format,jpg/quality,q_90/sharpen,50/resize,m_fill,w_360,h_360']
			},
			jiagechuli(e){
				if(e > 0){return `￥${e}`}
			},
			huoqujingweidu(){
				wx.getLocation({
					complete(res){
						console.log(res)
					}
				})
			},
			sui(e = 50000000){
				return Math.floor(Math.random()*e)
			},
			async loadData(){
				await uni.request({
					url: '/wanlshop/mchomepage/getMchomePage',
					data:{
						id: '6',
						lng: '126.693548',
						lat: '45.835396'
					},
					complete: res => {
						console.log(res.data.goods)
						if(res.res.code === 1){
							this.con = res.data
						}else{
							uni.showToast({
							    title: '服务器繁忙',
							    icon: 'none'
							});
						}
					}
				});
			},
			huoquxiangqing(){
				console.log(33)
				// wx.request({
				// 	url: 'https://www.lichu2025.cn/mchomepage/getMchomePage',
				// 	method: 'POST',
				// 	header: {"Content-Type": "application/x-www-form-urlencoded"},
				// 	data: {
				// 		id: 80
				// 	},
				// 	success(res){
				// 		console.log(res.data)
				// 	}
				// })
				
				console.log(44)
			}
		}
	}
</script>

<style lang="scss" scoped>
	.lunbo{
		position: relative;
		width: 750rpx;
		height: 497rpx;
		swiper{
			width: 750rpx;
			height: 497rpx;
		}
		image{
			width: 750rpx;
			height: 497rpx;
		}
	}
	.neirong{
		.touxiang{
			width: 100rpx;
			height: 97rpx;
			border-radius: 100rpx;
		}
		.daohang, .dianhua{
			width: 52rpx;
			height: 52rpx;
		}
		.dianhua{
			
		}
	}
</style>
